import { BaseEntity } from '@cool-midway/core'
import { Column, Entity } from 'typeorm'

/**
 * 新闻信息
 */
@Entity('news_info')
export class NewsInfoEntity extends BaseEntity {
  @Column({ comment: '标题' })
  title: string

  @Column({ comment: '封面图片' })
  cover: string

  @Column({ comment: '新闻内容', length: 2000 })
  content: string

  @Column({ comment: '状态', default: 1 })
  status: number

  @Column({ comment: '排序', default: 0 })
  index: number

  @Column({ comment: '发布日期' })
  releaseDate: Date
}
